<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>罗马/欧式壶介绍</title>

<link rel='stylesheet prefetch'	href='css/photoswipe.css'>
<link rel='stylesheet prefetch'	href='css/default-skin/default-skin.css'>
<link rel="stylesheet" href="css/style.css">

</head>

<body>

	<h2>罗马壶:</h2>
	<div id="links" class="my-gallery" itemscope itemtype="http://schema.org/ImageGallery">
	</div>
	<h2>&nbsp;</h2>
	<h2>欧式壶:</h2>
	<div id="links2" class="my-gallery" itemscope itemtype="http://schema.org/ImageGallery">
	</div>

	<!-- Root element of PhotoSwipe. Must have class pswp. -->
	<div class="pswp" tabindex="-1" role="dialog" aria-hidden="true">

		<!-- Background of PhotoSwipe. 
         It's a separate element, as animating opacity is faster than rgba(). -->
		<div class="pswp__bg"></div>

		<!-- Slides wrapper with overflow:hidden. -->
		<div class="pswp__scroll-wrap">

			<!-- Container that holds slides. PhotoSwipe keeps only 3 slides in DOM to save memory. -->
			<!-- don't modify these 3 pswp__item elements, data is added later on. -->
			<div class="pswp__container">
				<div class="pswp__item"></div>
				<div class="pswp__item"></div>
				<div class="pswp__item"></div>
			</div>

			<!-- Default (PhotoSwipeUI_Default) interface on top of sliding area. Can be changed. -->
			<div class="pswp__ui pswp__ui--hidden">

				<div class="pswp__top-bar">

					<!--  Controls are self-explanatory. Order can be changed. -->

					<div class="pswp__counter"></div>

					<button class="pswp__button pswp__button--close"
						title="Close (Esc)"></button>

					<button class="pswp__button pswp__button--share" title="Share"></button>

					<button class="pswp__button pswp__button--fs"
						title="Toggle fullscreen"></button>

					<button class="pswp__button pswp__button--zoom" title="Zoom in/out"></button>

					<!-- Preloader demo http://codepen.io/dimsemenov/pen/yyBWoR -->
					<!-- element will get class pswp__preloader--active when preloader is running -->
					<div class="pswp__preloader">
						<div class="pswp__preloader__icn">
							<div class="pswp__preloader__cut">
								<div class="pswp__preloader__donut"></div>
							</div>
						</div>
					</div>
				</div>

				<div
					class="pswp__share-modal pswp__share-modal--hidden pswp__single-tap">
					<div class="pswp__share-tooltip"></div>
				</div>

				<button class="pswp__button pswp__button--arrow--left"
					title="Previous (arrow left)"></button>

				<button class="pswp__button pswp__button--arrow--right"
					title="Next (arrow right)"></button>

				<div class="pswp__caption">
					<div class="pswp__caption__center"></div>
				</div>

			</div>
		</div>
	</div>
	<script src="js/jquery.min.js"></script>
	<script	src='js/photoswipe.min.js'></script>
	<script	src='js/photoswipe-ui-default.min.js'></script>
	<script>
var photos = [
{"id":"rome_01","title":"罗马壶"},
{"id":"rome_02","title":"罗马壶"},
{"id":"rome_03","title":"罗马壶"},
{"id":"rome_04","title":"罗马壶"},
{"id":"rome_05","title":"罗马壶"},
{"id":"rome_06","title":"罗马壶"},
{"id":"rome_07","title":"罗马壶"},
{"id":"rome_08","title":"罗马壶"},
{"id":"rome_09","title":"罗马壶"},
{"id":"rome_10","title":"罗马壶"},
{"id":"rome_11","title":"罗马壶"},
{"id":"rome_12","title":"罗马壶"}

]

var photos2 = [
{"id":"european_01","title":"欧式壶"},
{"id":"european_02","title":"欧式壶"},
{"id":"european_03","title":"欧式壶"},
{"id":"european_04","title":"欧式壶"},
{"id":"european_05","title":"欧式壶"},
{"id":"european_06","title":"欧式壶"},
{"id":"european_07","title":"欧式壶"},
{"id":"european_08","title":"欧式壶"},
{"id":"european_09","title":"欧式壶"},
{"id":"european_10","title":"欧式壶"},
{"id":"european_11","title":"欧式壶"},
{"id":"european_12","title":"欧式壶"}

]

/**
<figure itemprop="associatedMedia" itemscope itemtype="http://schema.org/ImageObject">
<a href="img/f2.jpg" itemprop="contentUrl" data-size="964x1024"> 
	<img src="img/f2.jpg"  width="75px" height="75px" itemprop="thumbnail" alt="Image description" />
</a>
<figcaption itemprop="caption description">Image caption2</figcaption>
</figure>
*/

var linksContainer = $('#links'), baseUrl;
// Add the demo images as links with thumbnails to the page:
$.each(photos, function (index, photo) {
	baseUrl = 'img/rome/' + photo.id;
	$('<figure/>').append(
		$('<a/>').prop('href', baseUrl + '.jpg').prop('title', photo.title)
		.attr('itemprop', 'contentUrl').attr('data-size', "964x1024")
		.append($('<img>').prop('src', baseUrl + '.jpg').attr("style","width:75px;height:75px;")
				.attr('itemprop', 'thumbnail')))
		.attr("itemprop", "associatedMedia").attr("itemtype", "http://schema.org/ImageObject")
		.attr('itemscope', '')
	.appendTo(linksContainer);
});

var linksContainer = $('#links2'), baseUrl;
//Add the demo images as links with thumbnails to the page:
$.each(photos2, function (index, photo) {
	baseUrl = 'img/european/' + photo.id;
	$('<figure/>').append(
		$('<a/>').prop('href', baseUrl + '.jpg').prop('title', photo.title)
		.attr('itemprop', 'contentUrl').attr('data-size', "964x1024")
		.append($('<img>').prop('src', baseUrl + '.jpg').attr("style","width:75px;height:75px;")
				.attr('itemprop', 'thumbnail')))
		.attr("itemprop", "associatedMedia").attr("itemtype", "http://schema.org/ImageObject")
		.attr('itemscope', '')
	.appendTo(linksContainer);
});

	</script>
	<script src="js/index.js"></script>

</body>
</html>
